﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="CatForm.aspx.cs"
Inherits="schedulelist.CatForm" MasterPageFile="~/Site.Master"%>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder4" runat="server">
    <table align="center" bgcolor="#C0C0C0">
<tr align="center">
<td>
<asp:Label ID="Label4" runat="server" Text="Categories"
Font-Size="20pt" ForeColor="#000000" Font-Bold="True"/>
</td>
</tr>
<tr>
<td>
<asp:GridView ID="GridView1" runat="server" ForeColor="Black" BorderWidth="2px" 
AutoGenerateColumns="false" Visible="true" BorderColor="Silver"
ShowHeader="true"
AllowPaging="true" PageSize="20"
onpageindexchanging="GridView1_PageIndexChanging"
OnRowDeleting="GridView1_RowDeleting" Font-Size="12pt"
OnRowEditing="GridView1_RowEditing"
HorizontalAlign="Center" RowStyle-HorizontalAlign="Center" BorderStyle="None">
<Columns >
<asp:TemplateField HeaderText="Id"   Visible="false" 
ItemStyle-Width="50" >
<ItemTemplate>
<asp:Label id="myLabel1" runat="server" 
Text='<%# Bind("Id")%>'  />
</ItemTemplate>

<ItemStyle Width="50px"></ItemStyle>
</asp:TemplateField>
<asp:TemplateField HeaderText="Name" ControlStyle-Width="100" HeaderStyle-Font-Italic="true" HeaderStyle-Font-Underline="true"  HeaderStyle-Font-Bold="false" ItemStyle-Width="60" ItemStyle-BackColor="#CCCCCC" ItemStyle-BorderColor="#C0C0C0"
 HeaderStyle-BackColor="#CCCCCC" HeaderStyle-BorderColor="#C0C0C0">
<ItemTemplate>
<asp:Label id="myLabel2"  runat="server"  Font-Names="Segoe Print"
Text='<%# Bind("name")%>'  />
</ItemTemplate>
<EditItemTemplate>
<asp:TextBox ID="myTextBox2" runat="server" Width="100"
Text='<%# Bind("name") %>'/>
</EditItemTemplate>
<FooterTemplate>
<asp:TextBox ID="myFooterTextBox2" runat="server"
Width="100" Text='<%# Bind("name") %>' />
</FooterTemplate>

<HeaderStyle BackColor="#CCCCCC" BorderColor="Silver"></HeaderStyle>

<ItemStyle BackColor="#CCCCCC" BorderColor="Silver" Width="120px"></ItemStyle>
</asp:TemplateField>
<asp:TemplateField HeaderText="Actions"  HeaderStyle-Font-Italic="true" HeaderStyle-Font-Underline="true"  HeaderStyle-Font-Bold="false" ItemStyle-Width="60" ItemStyle-BackColor="#CCCCCC" ItemStyle-BorderColor="#C0C0C0"
HeaderStyle-BackColor="#CCCCCC" HeaderStyle-BorderColor="#C0C0C0" >
<ItemTemplate>
<table>
    <tr><td>
    <asp:Button ID="ibDelete" runat="server" CommandName="Delete" 
    Text="Del"  Height="20" Width="30"/></td>
    <td><asp:Button ID="Button7" runat="server"   CommandName="Edit" Visible="true" 
    Text="Edit"  Height="20" Width="40"/></td>
    <td><asp:Button ID="Button2" runat="server" OnClick="Updating" Visible="false" 
    Text="Edit now"  Height="20" Width="75"/></td>
    <td><asp:Button ID="Button3" runat="server"  Visible = "false" OnClick="Undo"
    Text="Cancel"  Height="20" Width="65"/></td>
    <td><asp:Button ID="Button6" runat="server" OnClick="AED" Visible="false" 
    Text="Advanced item edit"  Height="20" Width="135"/></td>
    </tr>
    </table>
</ItemTemplate>
<FooterTemplate>
<table><tr><td>
<asp:Button ID="Button5" runat="server"  OnClick="QuickAd"  
    Text="Add"  Height="20" Width="50"/></td>
    <td><asp:Button ID="Button8" runat="server"  OnClick="Undo"
    Text="Cancel"  Height="20" Width="65"/></td>
    </tr>
    </table>
</FooterTemplate>

<HeaderStyle BackColor="#CCCCCC" BorderColor="Silver"></HeaderStyle>

<ItemStyle BackColor="#CCCCCC" BorderColor="Silver" Width="150px"></ItemStyle>
</asp:TemplateField>
</Columns>
    <EditRowStyle BackColor="#CCCCCC" BorderColor="Silver" />
    <FooterStyle BackColor="#CCCCCC" BorderColor="Silver" />
<PagerStyle HorizontalAlign ="Center" />

<RowStyle HorizontalAlign="Center" BorderColor="Silver"></RowStyle>
</asp:GridView>
</td>
</tr>
<tr>
<td>
    <asp:Button ID="Button9" runat="server" onclick="ibInsert_Click" 
        Text="Add category" />
    <asp:Button ID="Button10" runat="server" onclick="QAD" Text="Quick add" />
    </td>
<td>
    &nbsp;</td>
</tr>
</table>
</asp:Content>

